/**
 * path: 路由的跳转路径，如果后台菜单表中，相同name下的路由，其path最终以此文件中的路由路径为准，
 *       故菜单配置时，此项只能为选择框，且与name一一对应
 *
 * 注意 path 只是匹配路径 根据页面的路径 在router里匹配到对应的路径 然后加载指定的组件
 *
 * name: 路由的名称，必须全局唯一，如果未配置则可能导致keep-alive失效，用以匹配后台菜单表和路由表的路由
 * hidden: 路由是否隐藏，该项配置将被后台菜单表的配置覆盖
 * meta: {
 *   title: 菜单名称，此项配置将被后台菜单表的配置覆盖
 *   icon: 菜单图标，此项配置将被后台菜单表的配置覆盖
 *   noCache: 菜单是否缓存 true 不缓存
 *   noTageView:'菜单不存 tags里' true不存在 不进行记录tagsView里没有 
 *   affix:true   不可被删除缓存
 * }
 */
import Layout from '@/views/layout/Layout.vue';
import SeatsRouter from './SeatsRouter';
// 承德银行特色页面 - 6513
// import pages_6513 from './bank_6513'
// 齐鲁银行特色页面 - 6409
// import { pages_6409, statisticPages_6409 } from './bank_6409'

// const bankNo = localStorage.getItem('bankNo');
// console.log(bankNo,'bankNo');

const NebulaRouter: any[] = [
    {
        path: '/',
        name: '/',
        redirect: '/login',
    },
    {
        path: '/ticketSystem/midlePage',
        name: 'midlePage',
        meta: {
            title: '业务咨询',
        },
        component: () => import('@/views/ticketSystem/midlePage.vue'),
    },
    {
        path: '/login',
        name: 'Login',
        component: () => import('@/views/login/Login.vue'),
        meta: {
            title: '登录',
        },
    },

    // 联机交易模块 ---------------------------------------------------------------
    // {
    //     path: '/dealOnline',
    //     name: 'dealOnline',
    //     component: Layout,
    //     children: [
    //         {
    //             path: '/dealOnline/applicationProgress',
    //             name: 'applicationProgress',
    //             meta: {
    //                 title: '申请进度查询',
    //             },
    //             component: () => import('@/views/businessTransactions/dealOnline/applicationProgress.vue'),
    //         },
    //     ],
    // },
    // 业务统计 ---------------------------------------------------------------
    {
        path: '/businessStatistics',
        name: 'businessStatistics',
        component: Layout,
        children: [
            // 工单系统
            // 6409特有的业务统计页面
            // ...statisticPages_6409,
            // 公用页面
            {
                path: '/ticketSystem/information',
                name: 'information',
                meta: {
                    title: '业务咨询',
                },
                component: () => import('@/views/ticketSystem/information.vue'),
            },
            // 其他工单系统页面
            {
                path: '/ticketSystem/WFTYPECODE/:id',
                name: 'WFTYPECODE',
                meta: {
                    title: '工单系统',
                },
                component: () => import('@/views/ticketPaging/WFTYPECODE.vue'),
            },
            {
                path: '/ticketPaging/midlePage/:id',
                // 工单系统页面 不做缓存 路由name 和组件name 不要相同
                name: 'midlePage',
                meta: {
                    title: '工单跳转页',
                    noCache: true,
                    noTageView: true,
                },
                component: () => import('@/views/ticketPaging/midlePage.vue'),
            },
            {
                path: '/businessStatistics/serviceHistoey',
                name: 'serviceHistoey',
                meta: {
                    title: '服务历史',
                },
                // component:() => import('@/views/businessStatistics/serviceHistoey.vue')
                component: () => import('@/views/reportForm/businessStatistics/latestServiceHistory.vue'),
            },

            {
                path: '/businessStatistics/recentCallHistory',
                name: 'recentCallHistory',
                meta: {
                    title: '呼叫历史',
                },
                component: () => import('@/views/reportForm/businessStatistics/recentCallHistory.vue'),
            },
            {
                path: '/businessStatistics/insRecordExport',
                name: 'insRecordExport',
                meta: {
                    title: '分期付款业务流水表',
                },
                component: () => import('@/views/reportForm/businessStatistics/insRecordExport.vue'),
            },
            {
                path: '/businessStatistics/cancelCardReasonList',
                name: 'cancelCardReasonList',
                meta: {
                    title: '销卡原因明细查询',
                },
                component: () => import('@/views/reportForm/businessStatistics/cancelCardReasonList.vue'),
            },
            {
                path: '/businessStatistics/callSummaryReport',
                name: 'callSummaryReport',
                meta: {
                    title: '电话小结统计表',
                },
                component: () => import('@/views/reportForm/businessStatistics/callSummaryReport.vue'),
            },
            {
                path: '/businessStatistics/detailOfReasonCall',
                name: 'detailOfReasonCall',
                meta: {
                    title: '来电原因明细报表',
                },
                component: () => import('@/views/reportForm/businessStatistics/detailOfReasonCall.vue'),
            },
            //  报表系统
            {
                path: '/businessReport/ServiceSummaryRatio',
                name: 'ServiceSummaryRatio',
                meta: {
                    title: '服务小结占比',
                },
                component: () => import('@/views/reportForm/businessReport/ServiceSummaryRatio.vue'),
            },
            {
                path: '/businessReport/AgentServiceDetail',
                name: 'AgentServiceDetail',
                meta: {
                    title: '坐席服务明细',
                },
                component: () => import('@/views/reportForm/businessReport/AgentServiceDetail.vue'),
            },
            {
                path: '/businessReport/RepeatCallDetail',
                name: 'RepeatCallDetail',
                meta: {
                    title: '重复来电明细表',
                },
                component: () => import('@/views/reportForm/businessReport/RepeatCallDetail.vue'),
            },
            {
                path: '/businessReport/AgentReportStat',
                name: 'AgentReportStat',
                meta: {
                    title: '坐席报备统计表',
                },
                component: () => import('@/views/reportForm/businessReport/AgentReportStat.vue'),
            },
            {
                path: '/businessReport/AgentReportDetail',
                name: 'AgentReportDetail',
                meta: {
                    title: '坐席报备明细表',
                },
                component: () => import('@/views/reportForm/businessReport/AgentReportDetail.vue'),
            },
            {
                path: '/businessReport/SatisfactionStat',
                name: 'SatisfactionStat',
                meta: {
                    title: '满意度统计表',
                },
                component: () => import('@/views/reportForm/businessReport/SatisfactionStat.vue'),
            },
            {
                path: '/businessReport/IvrClickNum',
                name: 'IvrClickNum',
                meta: {
                    title: 'IVR点击量',
                },
                component: () => import('@/views/reportForm/businessReport/IvrClickNum.vue'),
            },
            {
                path: '/businessReport/ChangeShiftsDetail',
                name: 'ChangeShiftsDetail',
                meta: {
                    title: '交接班明细表',
                },
                component: () => import('@/views/reportForm/businessReport/ChangeShiftsDetail.vue'),
            },
            {
                path: '/businessReport/BusiAcceptTimeStat',
                name: 'BusiAcceptTimeStat',
                meta: {
                    title: '业务受理时长统计表',
                },
                component: () => import('@/views/reportForm/businessReport/BusiAcceptTimeStat.vue'),
            },
            {
                path: '/businessReport/HistoryIncomingData',
                name: 'HistoryIncomingData',
                meta: {
                    title: '客户历史进线数据',
                },
                component: () => import('@/views/reportForm/businessReport/HistoryIncomingData.vue'),
            },
            {
                path: '/businessReport/CallingOperationProcess',
                name: 'CallingOperationProcess',
                meta: {
                    title: '客户来电操作全流程轨迹',
                },
                component: () => import('@/views/reportForm/businessReport/CallingOperationProcess.vue'),
            },

        ],
    },
    // 当你的路由图太长时，你可以把它分割成小模块
    // 系统菜单
    SeatsRouter,
    {
        path: '/manage',
        name: 'menusetting',
        component: Layout,
        meta: {
            title: '管理平台',
        },
        children: [
            {
                path: '/manage/menusetting',
                name: 'menusetting',
                meta: {
                    title: '菜单管理',
                },
                component: () => import('@/views/systemManagement/menusetting/index.vue'),
            },
            {
                path: '/manage/businessMenu',
                name: 'businessMenu',
                meta: {
                    title: '业务菜单管理',
                },
                component: () => import('@/views/systemManagement/busiMenu/busiMenu.vue'),
            },
            {
                path: '/manage/templateMenu',
                name: 'templateMenu',
                meta: {
                    title: '模板菜单管理',
                    bz: '这个菜单好像没用用 下次遇见 还是没有到 就删除'
                },
                component: () => import('@/views/systemManagement/menusetting/templateMenu.vue'),
            },
            {
                path: '/index/authorizeManagement',
                name: 'authorizeManagement',
                meta: {
                    title: '角色权限管理',
                },
                component: () => import('@/views/managementPlatform/AuthorizeManagement.vue'),
            },
            {
                path: '/index/authorizeBusiness',
                name: 'authorizeBusiness',
                meta: {
                    title: '业务角色权限管理',
                },
                component: () => import('@/views/managementPlatform/AuthorizeManagement.vue'),
            },
            {
                path: '/index/lesseeManagement',
                name: 'lesseeManagement',
                meta: {
                    title: '租户管理',
                },
                component: () => import('@/views/managementPlatform/LesseeManagement.vue'),
            },
            {
                path: '/index/paramsManagement',
                name: 'paramsManagement',
                meta: {
                    title: '参数管理',
                },
                component: () => import('@/views/managementPlatform/ParamsManagement.vue'),
            },
            {
                path: '/index/IpAllocationCti',
                name: 'IpAllocationCti',
                meta: {
                    title: 'IP分机绑定管理',
                },
                component: () => import('@/views/managementPlatform/IpAllocationCti.vue'),
            },
            //
            // 1234
            {
                path: '/index/dictManagement',
                name: 'dictManagement',
                meta: {
                    title: '字典管理',
                },
                component: () => import('@/views/managementPlatform/DictManagement/DictManagement.vue'),
            },
            {
                path: '/index/menuAssignment',
                name: 'menuAssignment',
                meta: {
                    title: '菜单分配',
                },
                component: () => import('@/views/managementPlatform/menuAssignment.vue'),
            },
            {
                path: '/index/messageTempManagement',
                name: 'MessageTempManagement',
                meta: {
                    title: '短信模板管理',
                },
                component: () => import('@/views/managementPlatform/MessageTempManagement.vue'),
            },
            {
                path: '/information/postListManagement',
                name: 'postListManagement',
                meta: {
                    title: '寄送清单管理',
                },
                component: () => import('@/views/managementPlatform/Information/postListManagement.vue'),
            },
            {
                path: '/index/blackAndWhite',
                name: 'blackAndWhite',
                meta: {
                    title: '黑红名单管理',
                },
                component: () => import('@/views/managementPlatform/BlackAndWhite.vue'),
            },
            {
                path: '/index/custlabel',
                name: 'CustlabelManagement',
                meta: {
                    title: '客户标签管理',
                },
                component: () => import('@/views/managementPlatform/CustlabelManagement.vue'),
            },
            {
                path: '/index/departManagement',
                name: 'departManagement',
                meta: {
                    title: '机构管理',
                },
                component: () => import('@/views/managementPlatform/DepartManagement.vue'),
            },
            {
                path: '/index/userManagement',
                name: 'userManagement',
                meta: {
                    title: '用户管理',
                },
                component: () => import('@/views/managementPlatform/UserManagement.vue'),
            },
            {
                path: '/index/skillManagement',
                name: 'skillManagement',
                meta: {
                    title: '坐席技能组管理',
                },
                component: () => import('@/views/managementPlatform/skillManagement.vue'),
            },
            {
                path: '/index/noticeManagement',
                name: 'noticeManagement',
                meta: {
                    title: '公告管理',
                },
                component: () => import('@/views/managementPlatform/noticeManagement.vue'),
            },
            {
                path: '/index/lesseeManagerConfig',
                name: 'lesseeManagerConfig',
                meta: {
                    title: '租户管理员配置',
                },
                component: () => import('@/views/managementPlatform/LesseeManagerConfig.vue'),
            },
            {
                path: '/index/workPlace',
                name: 'workPlace',
                meta: {
                    title: '职场管理',
                },
                component: () => import('@/views/managementPlatform/workPlace.vue'),
            },
            {
                path: '/index/CompUserList',
                name: 'CompUserList',
                meta: {
                    title: '用户账号投诉关联',
                },
                component: () => import('@/views/managementPlatform/CompUserList.vue'),
            },
            {
                path: '/index/roleManagement',
                name: 'roleManagement',
                meta: {
                    title: '角色管理',
                },
                component: () => import('@/views/managementPlatform/roleManagement.vue'),
            },
            {
                path: '/index/reasonTypePfCall',
                name: 'reasonTypePfCall',
                meta: {
                    title: '来电原因配置',
                },
                component: () => import('@/views/managementPlatform/reasonTypePfCall.vue'),
            },
            {
                path: '/index/clientList',
                name: 'ClientList',
                meta: {
                    title: '路由策略客户名单导入',
                },
                component: () => import('@/views/systemManagement/clientList/ClientList.vue'),
            },
            {
                path: '/index/PhasedPlan',
                name: 'PhasedPlan',
                meta: {
                    title: '分期计划管理',
                },
                component: () => import('@/views/managementPlatform/DictManagement/PhasedPlan.vue'),
            },
            {
                path: '/index/CustomerRemarke',
                name: 'CustomerRemarke',
                meta: {
                    title: '客户标签管理',
                },
                component: () => import('@/views/managementPlatform/DictManagement/CustomerRemarke.vue'),
            },
            {
                path: '/index/teamManagement',
                name: 'teamManagement',
                meta: {
                    title: '坐席群组管理',
                },
                component: () => import('@/views/managementPlatform/teamManagement.vue'),
            },
            {
                path: '/information/qualityManagement',
                name: 'qualityManagement',
                meta: {
                    title: '质检管理',
                },
                component: () => import('@/views/managementPlatform/Information/qualityManagement.vue'),
            },
            {
                path: '/information/performanceManagement',
                name: 'performanceManagement',
                meta: {
                    title: '绩效管理',
                },
                component: () => import('@/views/managementPlatform/Information/performanceManagement.vue'),
            },
            {
                path: '/agentLogoutBackups/agentLogoutBackupList',
                name: 'agentLogoutBackupList',
                meta: {
                    title: '坐席签出报备',
                },
                component: () => import('@/views/systemManagement/agentLogoutBackups/agentLogoutBackupList.vue'),
            },
            {
                path: '/ivrmenumanger/IVRtree',
                name: 'c',
                meta: {
                    title: 'IVR语音菜单管理',
                },
                component: () => import('@/views/systemManagement/ivrmenumanger/ivr-tree.vue'),
            },
            {
                path: '/upload/fileUpload',
                name: 'fileUpload',
                meta: {
                    title: '文件上传',
                },
                component: () => import('@/views/managementPlatform/uploadFile.vue'),
            },
            {
                path: '/information/honorroll',
                name: 'HonorRoll',
                meta: {
                    title: '荣誉榜信息维护',
                },
                component: () => import('@/views/managementPlatform/Information/HonorRoll.vue'),
            },
            {
                path: '/information/workingschedule',
                name: 'WorkingSchedule',
                meta: {
                    title: '排班信息管理',
                },
                component: () => import('@/views/managementPlatform/Information/WorkingSchedule.vue'),
            },
            {
                path: '/systemmanagement/shiftmanagement',
                name: 'shiftManagement',
                meta: {
                    title: '班次管理',
                },
                component: () => import('@/views/systemManagement/shiftManagement/shiftManagement.vue'),
            },
            {
                path: '/information/learningGarden',
                name: 'learningGarden',
                meta: {
                    title: '学习园地管理',
                },
                component: () => import('@/views/managementPlatform/Information/learningGarden.vue'),
            },
            {
                path: '/voiceChannel/voiceChannelMonitor',
                name: 'voiceChannelMonitor',
                meta: {
                    title: '语音通道吞吐量监控',
                },
                component: () => import('@/views/reportForm/voiceChannelMonitor/voiceChannelMonitor.vue'),
            },
        ],
    },
    // 监控系统 /information/IPMInformation
    {
        path: '/monitorSystem',
        name: 'monitorSystem',
        component: Layout,
        meta: {
            title: '监控系统',
        },
        children: [
            {
                path: '/monitorSystem/custMonitor',
                name: 'custMonitor',
                meta: {
                    title: '坐席通话监听',
                },
                component: () => import('@/views/systemManagement/monitorSystem/custMonitor.vue'),
            },
        ],
    },
    // 添加404 页面 404 页面 要放到最后加载
    // {
    //     path:'*',
    //     redirect:'/404',
    //     hidden:true
    // }


];

export default NebulaRouter;
